<div style="width:100px; height:100px; background-color: red"></div><script src="jquery-1.12.4.min.js"></script>
<script>  var ele = $('div');  var w = ele.css('width');  var h = ele.css('height');  ele.css({border: '2px solid black', backgroundColor: '#ccc'});  console.log('div元素的宽：' + w + '，高：' + h);</script>